//# sourceURL=role-info.js

/**
 * 提交
 */
function saveDept(){
	$.ajax({  
		url: '/admin/role',
        type: $('#id').val() ? 'put' : 'post',  
        dataType: 'json', 
        data:$('#form-role').serialize(), 
        success: function (result) {  
        	parent.layer.msg(result.message, {icon:6,time:2000});
        	var index = parent.layer.getFrameIndex(window.name);
			parent.$('#childFormMsg').val("保存成功");
			parent.layer.close(index);
        },
        error:function(){
        	var index = parent.layer.getFrameIndex(window.name);
        	parent.layer.msg("保存失败", {icon:5,time:2000});
        	parent.layer.close(index);
        }
    });  
}